<script>
	$(function(){
		$('#orderDetail_grid').datagrid({   
			title:'订单详情',
		    url:'/orderDetail/grid',    
		    queryParams: {
				seach_order_id: '${po.id!}'
			},
		    
		    columns:[[    
		        {field:'logo',title:'商品图片',width:200,
		        formatter:function(value,row,index){
		        	return "<img src='"+value+"' height='60px'/>";
		        }},    
		        {field:'name',title:'商品名称',width:200},    
		        {field:'now_price',title:'价格',width:100,align:'right'}, 
		        {field:'product_num',title:'数量',width:100,align:'right'},
		        {field:'product_price',title:'总价',width:100,align:'right'}
		    ]],
		    toolbar : [],
		    pagination:false,
		    onDblClickRow:null    
		});
	})
</script>
<div  id="tt" class="easyui-tabs" style="width: 786px; height: 450px;">
	<div title="订单" style="padding:5px;">
	<table class="tableForm tableCss">
		<tr>
			<th>所属商户</th>
			<td colspan="3">${(po.shop.name)!}</td>
		</tr>
		<tr>
			<th>订单编号</th>
			<td colspan="3">${(po.order_no)!}</td>
			</tr>
		<tr>
			<th>下单客户</th>
			<td>${(po.customer.name)!}</td>
			<th>状态</th>
			<td>
				<#if po.status==0>
				待处理
				<#elseif po.status==1>
				已作废
				<#elseif po.status==2>
				已支付
				<#elseif po.status==3>
				已发货
				<#elseif po.status==4>
				已收货
				<#elseif po.status==5>
				已结单
				<#else>
				未知状态
				</#if>
			</td>
		</tr>
		<tr>
			<th>优惠金额(元)</th>
			<td>${(po.discount)!}</td>
			<th>总金额(元)</th>
			<td>${(po.all_money)!}</td>
		</tr>
		<tr>
			<th>支付方式</th>
			<td>
			<#if po.payment??>
			<#if po.payment==1>
				线下支付
				<#elseif po.payment==2>
				定金支付
				<#else>
				线上支付
			</#if>
			<#else>
			其他方式
			</#if>
			</td>
			<th>运费(元)</th>
			<td>${(po.postage)!'-'}</td>
		</tr>
		<tr>
			<th>运输方式</th>
			<td>${(po.postage_name)!}</td>
			<th>送货地址</th>
			<td>${(po.postAddress)!}</td>
		</tr>
		<tr>
			<th>定金(元)</th>
			<td>${(po.front_money)!'-'}</td>
			<th>待付款金额(元)</th>
			<td>
			<#if (po.payment??) &&(po.payment==1 || po.payment==2)>
				${(po.all_money)!0-(po.front_money)!0}
			<#else>
			-
			</#if>
			</td>
		</tr>
		<tr>
			<th>是否要发票</th>
			<td>
				<#if po.need_bill?? && po.need_bill==1>
					要
					<#else>
					否
				</#if>
			</td>
			<th>送货时间</th>
			<td>${(po.delivery_time)!}</td>
		</tr>
		<tr>
			<th>创建时间</th>
			<td>${(po.create_time)!}</td>
			<th>修改时间</th>
			<td>${(po.update_time)!}</td>
		</tr>
	<tr>
	</tr>
	</table>
	<table id="orderDetail_grid"></table> 
	</div>
</div>